package com.vitalfit.model.dto;

import jakarta.validation.constraints.Max;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.time.LocalDate;

@Data
public class FitnessPlanDTO {
    //NotBlank 用于String
    //NotNull 用于int
    //NotEmpty 用于集合

    @NotNull(message = "Plan type is required.")
    private String planType; // This will be converted to FitnessPlanTypeEnum in the service layer

    @NotNull(message = "Duration in months is required.")
    @Min(value = 6, message = "Duration must be at least 6 month.")
    @Max(value = 12, message = "Duration must be at most 12 months.")
    private int durationMonths;

    @NotNull(message = "Start date is required.")
    private LocalDate startDate;

    @NotNull(message = "Expiration date is required.")
    private LocalDate expirationDate;


}
